package com.njit.WeStudy.util;
import java.text.SimpleDateFormat;

public class DateFormat {
    public static java.sql.Timestamp format(java.util.Date date){
        SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
        String formatedTime = dateFormat.format(date);
        return java.sql.Timestamp.valueOf(formatedTime);
    }
}
